<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="z" uri="zz"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<%@include file="/views/common/common.jsp"%>
	<script type="text/javascript">
		function ImportCustomer(){
			var customid = $("#customid_id").val();
			if(isNotNull(customid)){
				$.messager.confirm('信息提示','您确定要执行吗？',function(r){
					if (r){
						$.ajax({
							type : "get",
							url : "SaveZXCustomer",
							data:{customid:customid},
							success : function(data) {
								if(data.code=='SUCCESS'){
									parent.alertMessager('导入客户成功');
									location.reload();
								}else{
									alertErrorMessager(''+data.msg);
								}

							},
							error: function (data) {
								$("#info_id").val('ajax错误：'+JSON.stringify(data));
							}
						});
					}
				});
			}else{
				parent.alertErrorMessager('直销用户编号不能为空');
			}
		}
	</script>
</head>
<body class="easyui-layout">
<div data-options="region:'north'" class="border-top-0 border-right-0 border-left-0" style="height:38px;overflow:hidden">
	<div id="ButtonHR" class="btn-group" role="group">
		<c:if test="${is_mobile=='1'}" >
			<button id="return_button" type="button" class="btn btn-light" onclick="window.location.href='user_center_mobile';"><i class="fa fa-hand-o-left"></i> 返回</button>
		</c:if>
		<button id="RunRechargeButton" type="button" class="btn btn-light" onclick="ImportCustomer();"><i class="fa fa-floppy-o"></i> 执行导入直销用户</button>
	</div>
</div>
<div data-options="region:'center',border:false">
	<z:column column_size="4" column_type="0" column_id="customid" column_name="直销用户编号" is_readonly="true" column_help="直销用户编号" />
	<z:column column_size="4" column_type="1" column_id="info" column_name="导入信息" column_help="导入信息" />
</div>

<%@include file="/views/common/body.jsp"%>
</body>
</html>